`ifndef TRANSACTION_SVH
`define TRANSACTION_SVH

typedef class config_info; // 提前声明数据类型

class transaction;
	bit [3:0] a;
	config_info cfg_info; // 定义句柄

	function new(input bit [3:0] a = 0);
		this.a = a;
		cfg_info = new(a);
	endfunction

	function void print(string name = "");
		$display("%s: a=%0h", name, a);
		cfg_info.print(name);
	endfunction
endclass

`endif
